<%@taglib prefix="s" uri="/struts-tags" %>
<%@page contentType="text/html;charset=UTF-8" pageEncoding="UTF-8"%>

<head>
    <title><s:text name="search.results"/></title>   
</head>

<link rel="stylesheet" type="text/css" href="${pageContext.request.contextPath}/css/search.css"/>
	
<form id="navigationSearch" action="SearchMarketGroups" method="get">
	<s:hidden id="id" name="id"/>
	
	<!-- Breadcrumbs -->
	<div class="breadCrumbs">
		<s:set var="parents" value="marketGroupParents"/>
		<s:if test="marketGroup != null"><a href="SearchMarketGroups"><s:text name="market.groups"/></a> ></s:if>
		<s:else><span class="current"><s:text name="market.groups"/></span> ></s:else>
		<s:iterator value="parents" var="current" end="0" begin="#parents.size - 1" step="-1">
			<a href="SearchMarketGroups?id=${current.id}">${current.name}</a> > 
		</s:iterator>
		<span class="current">${marketGroup.name}</span>
	</div>
	
	<!-- Main part -->
	<table id="resultsTable" class="completelyBordered searchTable">
		<s:iterator value="marketGroups" var="item" status="rowStatus">
				<tr class="${rowStatus.odd ? 'oddRow' : 'evenRow'}">
					<!-- td class="idCell">#${item.id}</td-->
					<td class="imgCell img32Cell" style="background-image: url(${pageContext.request.contextPath}/img/Icons/items/32_32/icon${item.icon.fileName}.png)"></td>					
					<td class="nameCell">
						<a href="${item.hasTypes ? 'Search?marketGroupId' : 'SearchMarketGroups?id'}=${item.id}">${item.name}</a>
					</td>
				</tr>
		</s:iterator>
	</table>
	
</form>
